package com.rany.day02;
/*
* 计算在-10.8到5.9之间，绝对值大于6或者小于2.1的整数有多少个?
* */
public class DemoMath {
    public static void main(String[] args) {
        double num1 = -10.8;
        double num2 = 5.9;
        int count = 0;
        for (int i =(int) num1;i < num2;i++){
            if (Math.abs(i)>6 || Math.abs(i)<2.1){
                count++;
            }
        }
        System.out.println(count);
    }
}
